package com.myfoon.action.backing.system;

import com.myfoon.model.ejb.CountryEJBLocal;
import com.myfoon.model.entity.CountryName;
import com.myfoon.view.application.MyConstants;
import com.myfoon.view.context.helper.EJBReceiver;

import java.util.List;

import javax.ejb.EJB;

public class CountryBean {
    public CountryBean() {
    }
    
    public List<CountryName> findAllByLang(String language) {
        EJBReceiver receiver = new EJBReceiver();
        CountryEJBLocal local;
        local = (CountryEJBLocal)(receiver.receiveEJB(MyConstants.jndiName + "CountryEJB/local"));        
        
        return local.findAll(language);
    }
}
